class AddColumnToClients < ActiveRecord::Migration
  def self.up
    add_column :clients, :rue, :string
    add_column :clients, :cp, :string
    add_column :clients, :ville, :string
    add_column :clients, :pays, :string
    add_column :clients, :tel, :string
    add_column :clients, :fax, :string
    add_column :clients, :mail, :string
    add_column :clients, :tel_portable, :string
    add_column :clients, :garder_historique, :boolean
    add_column :clients, :numero_tva, :float
    add_column :clients, :numero_bos, :float
    add_column :clients, :compte_banquaire, :integer
    add_column :clients, :exoneration_tva, :boolean
    add_column :clients, :societe_id, :integer
    add_column :clients, :contact_societe, :boolean
    add_column :clients, :numero_securite_sociale, :string
    add_column :clients, :type_client, :string
    add_column :clients, :document, :string
    add_column :clients, :expire, :date
    add_column :clients, :passeport, :string
    add_column :clients, :langue, :string
    add_column :clients, :numero_immatriculation, :string
    add_column :clients, :numero_special, :string
    add_column :clients, :date_de_naissance, :date
    add_column :clients, :lieu_de_naissance, :string
    add_column :clients, :numero_carte_de_credit, :string
    add_column :clients, :code_cc, :string
    add_column :clients, :date_expiration_cc, :date
    add_column :clients, :code_courrier, :text
    add_column :clients, :info_carnet_adresse, :text
    add_column :clients, :info_additionnelle, :text
  end

  def self.down
    remove_column :clients, :rue
    remove_column :clients, :cp
    remove_column :clients, :ville
    remove_column :clients, :pays
    remove_column :clients, :tel
    remove_column :clients, :fax
    remove_column :clients, :mail 
    remove_column :clients, :tel_portable
    remove_column :clients, :garder_historique
    remove_column :clients, :numero_tva
    remove_column :clients, :numero_bos
    remove_column :clients, :compte_banquaire
    remove_column :clients, :exoneration_tva
    remove_column :clients, :societe_id
    remove_column :clients, :contact_societe
    remove_column :clients, :numero_securite_sociale
    remove_column :clients, :type_client
    remove_column :clients, :document
    remove_column :clients, :expire
    remove_column :clients, :passeport
    remove_column :clients, :langue
    remove_column :clients, :numero_immatriculation
    remove_column :clients, :numero_special
    remove_column :clients, :date_de_naissance
    remove_column :clients, :lieu_de_naissance
    remove_column :clients, :numero_carte_de_credit
    remove_column :clients, :code_cc
    remove_column :clients, :date_expiration_cc
    remove_column :clients, :code_courrier
    remove_column :clients, :info_carnet_adresse
    remove_column :clients, :info_additionnelle
  end
end
